<div class="bjui-pageContent tableContent">
	<form id="j_pwschange_form" action="${rootpath}/Login/logincheck" data-toggle="validate" method="post" onsubmit="return mysubmit();">
		<input type="hidden" id="j_password_new" name="userpassword">
		<input type="hidden" name="reloadtab" value="true">
		<input type="hidden" id="j_randomKey" name="t"/>
		<div class="pageFormContent" data-layout-h="0">
            <hr>
            <div class="form-group">
                <label for="j_username" class="control-label x85">用户名：</label>
                <input readonly="readonly" type="text" data-rule="required" name="username" id="j_username" value="${username!}" placeholder="" size="20">
            </div>
            <div class="form-group" style="margin: 20px 0 20px; ">
                <label for="j_password" class="control-label x85">密码：</label>
                <input type="password" data-rule="required" id="j_password" value="" placeholder="" size="20">
            </div>
            <div class="form-group">
                <label for="j_captcha" class="control-label x85">验证码：</label>
                <input type="text" data-rule="required" name="captcha" id="j_captcha" value="" placeholder="" autocomplete="off" size="20">
            </div>
            <div class="form-group">
                <label for="captcha_img" class="control-label x85"></label>
                <img id="captcha_img" alt="点击更换" title="点击更换" src="" style="cursor: pointer;">
            </div>
		</div>
		<div class="bjui-pageFooter">
            <ul>
                <li><button type="submit" class="btn-default">登陆</button></li>
            </ul>
		</div>
	</form>
</div>
<script type="text/javascript">
$(function() {
	changeCode();
	$("#captcha_img").click(function(){
		changeCode();
	});
});
function mysubmit(){
	$("#j_password_new").val(md5($("#j_password").val()));
	return true;
}
function genTimestamp(){
	var time = new Date();
	return time.getTime();
}
function changeCode(){
	var j_randomKey = genTimestamp();
	$("#j_randomKey").val(j_randomKey);
	$("#captcha_img").attr("src", "${rootpath}/Login/captcha?t="+j_randomKey);
}
</script>